package com.hrbxlh.virtualization.controller;

import com.hrbxlh.virtualization.result.Result;
import com.hrbxlh.virtualization.service.CourseService;
import com.hrbxlh.virtualization.vo.ImageAllocationVO;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

import java.util.List;

/**
 * @author cheer
 */
@RestController
@RequestMapping("/course")
public class CourseController {

    @Autowired
    private CourseService courseService;

    @RequestMapping("/queryImageAllocate")
    public Result<List<ImageAllocationVO>> queryImageAllocate(Integer chapterId){
        List<ImageAllocationVO> imageAllocationVOList = courseService.queryImageAllocate(chapterId);
        return Result.success(imageAllocationVOList);
    }
}
